<!DOCTYPE html>
<html lang="zh-CN">
<head>
  <meta charset="utf-8">
  <title>Settings &laquo; Admin</title>
  <link rel="stylesheet" href="../assets/vendors/bootstrap/css/bootstrap.css">
  <link rel="stylesheet" href="../assets/vendors/font-awesome/css/font-awesome.css">
  <link rel="stylesheet" href="../assets/css/admin.css">
</head>
<body>
  <div class="main">
    <nav class="navbar">
      <button class="btn btn-default navbar-btn fa fa-bars"></button>
      <ul class="nav navbar-nav navbar-right">
        <li><a href="profile.html"><i class="fa fa-user"></i>个人中心</a></li>
        <li><a href="login.html"><i class="fa fa-sign-out"></i>退出</a></li>
      </ul>
    </nav>
    <div class="container-fluid">
      <div class="page-title">
        <h1>网站设置</h1>
      </div>
      <!-- 有错误信息时展示 -->
      <!-- <div class="alert alert-danger">
        <strong>错误！</strong>发生XXX错误
      </div> -->
      <form class="form-horizontal">
        <!-- 模板文件 -->
      </form>
    </div>
  </div>
  <%- include('./layouts/admin_aside.ejs');%>
  <script type='text/template' id='settingTemp'>
    <div class="form-group">
      <label for="site_logo" class="col-sm-2 control-label">网站图标</label>
      <div class="col-sm-6">
        <input id="site_logo" name="site_logo" type="hidden" value='{{data[1].value}}'>
        <label class="form-image"  style='background:#000'>
          <input id="logo" type="file">
          <img src="{{data[1].value}}">
          <i class="mask fa fa-upload"></i>
        </label>
      </div>
    </div>
    <div class="form-group">
      <label for="site_name" class="col-sm-2 control-label">站点名称</label>
      <div class="col-sm-6">
        <input id="site_name" name="site_name" class="form-control" type="type" placeholder="站点名称" value='{{data[2].value}}'>
      </div>
    </div>
    <div class="form-group">
      <label for="site_description" class="col-sm-2 control-label">站点描述</label>
      <div class="col-sm-6">
        <textarea id="site_description" name="site_description" class="form-control" placeholder="站点描述" cols="30" rows="6">{{data[3].value}}</textarea>
      </div>
    </div>
    <div class="form-group">
      <label for="site_keywords" class="col-sm-2 control-label">站点关键词</label>
      <div class="col-sm-6">
        <input id="site_keywords" name="site_keywords" class="form-control" type="type" placeholder="站点关键词" value='{{data[4].value}}'>
      </div>
    </div>
    <div class="form-group">
      <label class="col-sm-2 control-label">评论</label>
      <div class="col-sm-6">
        <div class="checkbox">
          <label><input id="comment_status" name="comment_status" type="checkbox" {{data[6].value == 1?'checked':''}}>开启评论功能</label>
        </div>
        <div class="checkbox">
          <label><input id="comment_reviewed" name="comment_reviewed" type="checkbox"  {{data[7].value == 1?'checked':''}}>评论必须经人工批准</label>
        </div>
      </div>
    </div>
    <div class="form-group">
      <div class="col-sm-offset-2 col-sm-6">
        <input type="button" class="btn btn-primary btnSave" value='保存设置'>
      </div>
    </div>
  </script>
  <script src="/assets/vendors/jquery/jquery.min.js"></script>
  <script src="../assets/vendors/bootstrap/js/bootstrap.js"></script>

  <script src="/assets/vendors/template/template.js"></script>
  <script src="/assets/js/settings.js"></script>
</body>
</html>
